<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
    #foo > ul:first-child >li:nth-of-type(2){
        color: red;
    }
    </style>

</head>
<body>
    <div>
        <ol>
            <li>
                D
            </li>
            <li>
                D
            </li>
            <li>
                B
            </li>
            <li>
                A
            </li>
            <li>
                D
            </li>
            <li>
            偶数行为红色补充代码<br>
            #foo  ul:first-of-type > li:nth-of-type(even)
            </li>
            <li>
                word位置代码<br>
                var a = "world"
                var b = "hello world"
                console.log(b.indexOf(a))
            </li>
            <li>
            转换2进制代码<br>
            var a = 123;<br>
            console.log(a.toString(2);
        </li>
            <li>
                输出当前月份：<br>
                console.log( new Date().getMonth()+ 1);
            </li>
            <li>
                两只香，一只点燃一头，一只点燃两头，当点燃两头的香点完时，正好是半个小时，再次点燃另一只香的未被点燃的一头时，等燃尽正好是15分钟
            </li>
        </ol>
    </div>

    </div>
    
    <script>
    </script>
</body>
</html>